(define square
  (lambda (x) (* x x)))

(define sum-squares
  (lambda (lst)
    (if (null? lst)
        0
        (+ (square (car lst))
           (sum-squares (cdr lst))))))

(sum-squares '(1 2 3 4))

(define norm-2d
  (lambda (a b)
    (sqrt (sum-squares (list a b)))))

(define norm-3d
  (lambda (a b c)
    (sqrt (sum-squares(list a b c)))))

(define (norm . points)
  (sqrt (sum-squares points)))

(define norm
  (lambda points
    (sqrt (sum-squares points))))

(norm 3 4 10 2 3 5 6 )
